package gjtx2;

import java.util.Scanner;

public class FindTime {
    public static void main(String[] args) {
        Scanner in = new Scanner(System.in);
        System.out.println("输入两个字符串！");
        String a = in.next();
        String b = in.next();
        int k = 0;
        while (true) {
            if (a.indexOf(b) < 0) {
                break;
            } else {
                k++;
                a = a.substring(a.indexOf(b)+1);
            }

        }
        System.out.println("次数是："+k);
    }
}
